// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'

import VueI18n from 'vue-i18n'
import {
  messages
} from './backviews/common/i18n'
import './assets/css/icon.css'
import './backviews/common/directives'
import 'babel-polyfill'

import ElementUI from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'

// 引入axios
import axios from 'axios'
// 引入 utls.js
import {
  domain
} from './utils/url.js'
Vue.use(VueI18n)
const i18n = new VueI18n({
  locale: 'zh',
  messages
})
Vue.use(ElementUI)

// 配置axios
// url1,url2地址
axios.defaults.baseM1URL = domain.Base_M1_URL
axios.defaults.baseM2URL = domain.Base_M2_URL
axios.defaults.baseM3URL = domain.Base_M3_URL
axios.defaults.baseM4URL = domain.Base_M4_URL

/* eslint-disable no-new */
new Vue({
  router,
  i18n,
  render: h => h(App)
}).$mount('#app')
